package com.ruoyi.scyf.controller;

import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.common.core.web.page.TableDataInfo;
import com.ruoyi.scyf.domain.TestDomain;
import com.ruoyi.scyf.service.TestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @packageName: com.ruoyi.scyf.controller
 * @user: andyliu
 * @date: 2023/2/22 10:47
 * @email 115176513@qq.com
 * @description: TODO
 */
@RestController
@RequestMapping("/test")
public class TestController {
    @Autowired
    private TestService testService;
    @PostMapping("/save")
    private AjaxResult save(TestDomain domain){
        return AjaxResult.success(testService.saveOrUpdate(domain));
    }
}
